package package1;

import java.util.Scanner;

public class Class1 {
    public static void main(String[] args) {
        while (true) {
            System.out.println("请输入父亲身高：");
            int f = new Scanner(System.in).nextInt();
            System.out.println("请输入母亲身高：");
            int m = new Scanner(System.in).nextInt();
            System.out.println("请输入性别：");
            String a = new Scanner(System.in).next();
//            equals   用于字符串比较
            if (a.equals("男")) {
                System.out.println("儿子身高（cm）=" + (f + m) + "*" + 1.08 + "/" + 2);
            } else {
                System.out.println("女儿身高（cm）=" + (f * 0.923 + m) + "/" + 2);break;
            }
        }
    }
}